<template>
  <van-tabbar route> 
    <van-tabbar-item replace to="/home" icon="wap-home-o">首页</van-tabbar-item>
    <van-tabbar-item replace to="/catelist" icon="apps-o">分类</van-tabbar-item>
    <van-tabbar-item replace to="/worthbuy" icon="good-job-o">值得买</van-tabbar-item>
    <van-tabbar-item replace to="/cart" icon="shopping-cart-o">购物车</van-tabbar-item>
    <van-tabbar-item replace to="/personal" icon="user-o">个人</van-tabbar-item>
  </van-tabbar>
</template>

<script>
// 引入Tabbar所需组件
// import { Tabbar, TabbarItem } from 'vant'; 以实现按需引入
export default {
  name: "myTabbar",
  // 现已实现按需引入
  // components:{Tabbar,TabbarItem}
};
</script>

<style lang="less" scoped>
  // 使用深度选择器对选中颜色进行修改
  /deep/ .van-tabbar-item--active{
    color: #dd1a21;
  }
</style>